package com.cuitrip.business.search.ui;

import android.content.Context;
import android.graphics.Paint;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import com.cuitrip.business.search.model.HotWord;
import com.cuitrip.service.R;
import com.lab.adapter.BaseHolderView;
import com.lab.adapter.IAdapterData;

import butterknife.ButterKnife;
import butterknife.Bind;

/**
 * 热门词
 * Created by ak
 */
public class HotWordGridItemHolderView extends BaseHolderView {

    @Bind(R.id.hot_word_item)
    TextView text;

    public HotWordGridItemHolderView(Context context) {
        super(context, R.layout.hot_word_grid_item);
    }

    @Override
    public void initView(View rootView) {
        ButterKnife.bind(this);
    }


    @Override
    public void bindData(IAdapterData data, int position) {
        if (data instanceof HotWord){
            HotWord hotWord = (HotWord) data;
            text.setText(hotWord.getText());
        }
    }


    @Override
    protected void onDetachedFromWindow() {
        super.onDetachedFromWindow();
    }

}
